<!--
 * @Author: byron
 * @Date: 2021-08-31 18:12:25
 * @LastEditTime: 2021-08-31 18:19:11
-->

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div id="test"></div>

    <!-- 引入必要的js库 -->
    <script type="text/javascript" src="../../lib/react.development.js"></script>
    <script type="text/javascript" src="../../lib/react-dom.development.js"></script>
    <!-- 引入babel库进行语法转化 -->
    <script type="text/javascript" src="../../lib/babel.min.js"></script>
    <script type="text/javascript" src="../../lib/prop-types.js"></script>
    <script type="text/babel">
        function Person(props){
        console.log(props);
        const {name,sex,age} = props
        return (
            <ul>
                <li>姓名：{name}</li>
                <li>性别：{sex}</li>
                <li>年龄：{age}</li>
            </ul>
        )
    }
    ReactDOM.render(<Person name='王灿' age='18'  sex='男'/> ,document.getElementById("test"))
    </script>
</body>

</html>